package com.slz3.business.module.socialManagement.socSign.steward;

import com.slz3.business.frame.response.RR;
import com.slz3.business.frame.response.ResInfo;
import com.slz3.business.module.socialManagement.socSign.domain.SocSign;
import com.slz3.business.module.socialManagement.socSign.domain.SocSignCondition;
import org.springframework.stereotype.Component;
import org.springframework.web.reactive.function.server.ServerRequest;
import org.springframework.web.reactive.function.server.ServerResponse;
import reactor.core.publisher.Mono;
@Component
public class SocSignResAtomic {

    public Mono<ServerResponse> add_$SocSignUpdateLock(ServerRequest req, SocSign socSign) {
        return SocSignResSafeValid.add(req, socSign) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                SocSignResExecutor.add(req, socSign);
    }

    public  Mono<ServerResponse> delete_$SocSignUpdateLock(ServerRequest req, SocSignCondition socSignCondition) {
        return SocSignResSafeValid.delete(req, socSignCondition) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                SocSignResExecutor.delete(req);
    }

    public Mono<ServerResponse> modify_$SocSignUpdateLock(ServerRequest req, SocSign socSign) {
        return SocSignResSafeValid.modify(req, socSign) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                SocSignResExecutor.modify(req, socSign);
    }

    public Mono<ServerResponse> info_$SocSignUpdateLock(ServerRequest req) {
        return SocSignResSafeValid.info(req) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                SocSignResExecutor.info(req);
    }

    public  Mono<ServerResponse> auditSubmit_$SocSignUpdateLock(ServerRequest req, SocSignCondition socSignCondition) {
        return SocSignResSafeValid.auditSubmit(req, socSignCondition) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                SocSignResExecutor.auditSubmit(req);
    }

    public  Mono<ServerResponse> audit_$SocSignUpdateLock(ServerRequest req, SocSignCondition socSignCondition) {
        return SocSignResSafeValid.audit(req, socSignCondition) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                SocSignResExecutor.audit(req);
    }

    public  Mono<ServerResponse> auditReject_$SocSignUpdateLock(ServerRequest req, SocSignCondition socSignCondition) {
        return SocSignResSafeValid.auditReject(req, socSignCondition) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                SocSignResExecutor.auditReject(req);
    }


    public  Mono<ServerResponse> usingEnable_$SocSignUpdateLock(ServerRequest req, SocSignCondition socSignCondition) {
        return SocSignResSafeValid.usingEnable(req, socSignCondition) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                SocSignResExecutor.usingEnable(req);
    }

    public  Mono<ServerResponse> usingDisable_$SocSignUpdateLock(ServerRequest req, SocSignCondition socSignCondition) {
        return SocSignResSafeValid.usingDisable(req, socSignCondition) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                SocSignResExecutor.usingDisable(req);
    }
}
